<html>
<?php 
include 'connexion_bd.php';
session_start();
$req='SELECT COUNT(id_rub) FROM rubriques';
$res=mysql_query($req);
$nb_rub=mysql_fetch_row($res);

$rub=$_POST["rubrique"];
$requete='INSERT INTO rubriques VALUES ("'.$nb_rub[0].'","'.$rub.'")';
mysql_query($requete);

mysql_close ();
?>
</html>
